package com.chenjl.transport;

import java.net.InetSocketAddress;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.chenjl.transport.support.NettyClient;
/**
 * 
 * 2016-9-2 13:49:50
 * @author chenjinlong
 */
public abstract class AbstractClient {
	protected static final Logger logger = LoggerFactory.getLogger(NettyClient.class);
	
	protected volatile boolean close = false;
	
	public boolean isClose() {
		return close;
	}
	public void send(Object object) {
		this.send(object,false);
	}
	
	public abstract void connect();
	public abstract void reconnect();
	public abstract boolean isConnect();
	public abstract void close();
	public abstract void send(Object object,boolean sent);
	public abstract InetSocketAddress getLocalAddress();
	public abstract InetSocketAddress getRemoteAddress();
}